<?php 
	class options{
		function __construct(){
			FunctionsHelper::includeFiles(
					array(
							ADMINISTRATOR_MODEL_DIRECTORY . 'model.php',
							ADMINISTRATOR_MODEL_DIRECTORY . 'option.php'
					)
			);
		}

		public function getAll(){
			$arrOptions = array();
			$arrResult = Option::getAll();
		
			foreach($arrResult as $option){
				$arrOptions[] = new Option($option);
			}
			return $arrOptions;
		}
		
		public function getOption($arrInitialValue = null){
			if (empty($arrInitialValue))
				return new Option();
		
			$option = new Option($arrInitialValue);
		
			$option = $option->getOption();
			if (empty($option))
				return new Option();
				
			return new Option($option[0]);
		}
	}

?>